#ifndef CLIENTSERVERCOMMON_H
#define CLIENTSERVERCOMMON_H

#include <e32base.h>
#include <s32strm.h>

// CONSTANTS
_LIT( KIAPServerName,"QIAPServer" ); // Server name
_LIT( KIAPServerFileName,"QIAPServer.exe" ); // Server name
_LIT( KIAPServerSemaphoreName, "IAPServerSemaphore" );

const TUid KServerUid3 = {0x2005E5EA}; 
		
// The server version. A version must be specified when
// creating a session with the server.
const TUint KIAPServMajorVersionNumber=0;
const TUint KIAPServMinorVersionNumber=1;
const TUint KIAPServBuildVersionNumber=1;

// DATA TYPES
// Opcodes used in message passing between client and server
enum TIAPServRqst
{
    EIAPServPurcase,
    EIAPServProductData,
    EIAPServUserAndData
};

// Product data transfer class
class TProductData
      {
public:
      TBuf8<20>  productInformation;	//displayname OVI https://publish.ovi.com/content_items/
  									//Format 2-16 alphanumerical characters
      TBuf8<500> description;
      TBuf8<30> 	shortDescription;
      TBuf8<6> 	price;
      TBuf8<10> 	productId;
      TInt		appWinGroup; // client application window group
      };

// other IAP requests data transfer class
class TIAPrequestData
      {
public:
      TBuf8<2000> 	payload; 	 // can contain auth digest or purchase ticket 
      TInt			appWinGroup; // client application window group
      };

#endif // CLIENTSERVERCOMMON_H
